<!--
*Author：jxx
 *Contact：283591387@qq.com
 *代码由框架生成,任何更改都可能导致被代码生成器覆盖
 *业务请在@/extension/aftersaleinfo/contract_az_mx/q_contract_az_mx.js此处编写
 -->
<template>
    <view-grid ref="grid"
               :columns="columns"
               :detail="detail"
               :editFormFields="editFormFields"
               :editFormOptions="editFormOptions"
               :searchFormFields="searchFormFields"
               :searchFormOptions="searchFormOptions"
               :table="table"
               :extend="extend">
    </view-grid>
</template>
<script>
    import extend from "@/extension/aftersaleinfo/contract_az_mx/q_contract_az_mx.js";
    import { ref, defineComponent } from "vue";
    export default defineComponent({
        setup() {
            const table = ref({
                key: 'ID',
                footer: "Foots",
                cnName: '合同商品安装明细',
                name: 'contract_az_mx/q_contract_az_mx',
                url: "/q_contract_az_mx/",
                sortName: "htid"
            });
            const editFormFields = ref({});
            const editFormOptions = ref([]);
            const searchFormFields = ref({"htid":"","bm":"","mc":"","wsqsl":[null,null]});
            const searchFormOptions = ref([[{"title":"合同编码","field":"htid","type":"like"},{"title":"编码","field":"bm","type":"like"},{"title":"名称","field":"mc","type":"like"},{"title":"未申请数量","field":"wsqsl","type":"range"}]]);
            const columns = ref([{field:'ID',title:'ID',type:'guid',width:110,hidden:true,require:true,align:'left'},
                       {field:'htid',title:'合同编码',type:'string',width:150,align:'left',sort:true},
                       {field:'bm',title:'编码',type:'string',width:110,align:'left'},
                       {field:'mc',title:'名称',type:'string',width:220,align:'left'},
                       {field:'gg',title:'规格',type:'string',width:110,align:'left'},
                       {field:'htsl',title:'合同数量',type:'float',width:110,align:'left'},
                       {field:'wsqsl',title:'未申请数量',type:'float',width:140,align:'left'},
                       {field:'sqshzsl',title:'审核中申请安装数量',type:'float',width:140,require:true,align:'left'},
                       {field:'yazsl',title:'已安装数量',type:'float',width:110,require:true,align:'left'},
                       {field:'azzsl',title:'安装中数量',type:'float',width:110,require:true,align:'left'},
                       {field:'shzt',title:'发货状态',type:'int',bind:{ key:'发货状态',data:[]},width:110,align:'left'}]);
            const detail = ref({
                cnName: "#detailCnName",
                table: "#detailTable",
                columns: [],
                sortName: "",
                key: ""
            });
            return {
                table,
                extend,
                editFormFields,
                editFormOptions,
                searchFormFields,
                searchFormOptions,
                columns,
                detail,
            };
        },
    });
</script>
